---
layout: default
---

<div class="container-fluid" style="margin-top:20px">
  <div class="container-fluid">
    <div class="row">
      <ol class="breadcrumb">
        <li><a href="{{site.baseurl}}/">Home</a></li>
        <li><a href="{{site.baseurl}}/repos">Repos</a></li>
        <li class="active">{{page.repo.name}}</li>
        <!--<li class="active">{{page.instance.name}}</li>-->
      </ol>
    </div>
    <div class="row">
      {% include distro_switch.html %}
    </div>
    <div class="row">
      &nbsp;
    </div>
    <div class="row">
      {% include repo_info.html %}
    </div>
  </div>
</div>

{% for distro in page.all_distros %}
  <div class="distro distro-{{distro}}">
    <div class="container-fluid">
      {% if page.available_distros[distro] or page.available_older_distros[distro] %}
        {% assign repo = page.repo %}
        <div class="panel panel-default">
          {% assign snapshot = page.repo.snapshots[distro] %}
          <div class="panel-heading"><h3 class="panel-title">Repository Summary</h3></div>
          <div class="panel-body" style="overflow-x: auto">
            {% include repo_summary.html %}
          </div>
        </div>
        <div class="panel panel-default">
          <div class="panel-heading"><h3 class="panel-title">Packages</h3></div>
          <div class="panel-body">
            {% assign n_packages = page.repo.snapshots[distro].packages | size %}
            {% if n_packages > 0 %}
              <table class="table table-condensed table-hover table-striped">
                <thead>
                  <tr>
                    <th>Name</th>
                    <th>Version</th>
                  </tr>
                </thead>
                <tbody>
                {% for p in page.repo.snapshots[distro].packages %}
                  <tr>
                    <td><a href="{{site.baseurl}}/p/{{p[1].name}}/{{page.repo.id}}">{{ p[1].name }}</a></td>
                    <td>{{ p[1].data.version }}</td>
                  </tr>
                {% endfor %}
                </tbody>
              </table>
            {% else %}
              <em>No packages found.</em>
            {% endif %}
          </div>
        </div>

        <div class="panel panel-default">
          <div class="panel-heading"><h3 class="panel-title">README</h3></div>
          <div class="panel-body">
            {% if page.repo.snapshots[distro].data.readme %}
              {{ page.repo.snapshots[distro].data.readme_rendered }}
            {% else %}
              <em>No README found.</em>
            {% endif %}
          </div>
        </div>

        <div class="panel panel-default">
          <div class="panel-heading"><h3 class="panel-title">CONTRIBUTING</h3></div>
          <div class="panel-body">
            {% if page.repo.snapshots[distro].data.contributing %}
              {{ page.repo.snapshots[distro].data.contributing_rendered }}
              <hr id="{{distro}}-contribute-lists">
              <ul class="nav nav-tabs nav-justified" id="{{distro}}-contribute-lists-tabs">
                <li class="better-tabs active">
                  <a href="#{{distro}}-contribute-lists-help-wanted" data-toggle="tab"><span class="contribute-lists-help-wanted-count label label-primary">0</span> Help Wanted</a>
                </li>
                <li class="better-tabs">
                  <a href="#{{distro}}-contribute-lists-good-first-issue" data-toggle="tab"><span class="contribute-lists-good-first-issue-count label label-primary">0</span> Good First Issue</a>
                </li>
                <li class="better-tabs">
                  <a href="#{{distro}}-contribute-lists-pull-requests" data-toggle="tab"><span class="contribute-lists-pull-requests-count label label-primary">0</span> Pull Requests to Review</a>
                </li>
              </ul>
              <div class="tab-content contribute-lists">
                <div class="tab-pane active" id="{{distro}}-contribute-lists-help-wanted">
                  <div class="contribute-lists-help-wanted"></div>
                </div>
                <div class="tab-pane" id="{{distro}}-contribute-lists-good-first-issue">
                  <div class="contribute-lists-good-first-issue"></div>
                </div>
                <div class="tab-pane" id="{{distro}}-contribute-lists-pull-requests">
                  <div class="contribute-lists-pull-requests"></div>
                </div>
              </div>
            {% else %}
              <em>No CONTRIBUTING.md found.</em>
            {% endif %}
          </div>
        </div>

        {% assign n_errors = page.repo.errors | size %}
        {% if n_errors > 0 %}
          <div class="panel panel-danger">
            <div class="panel-heading"><h3 class="panel-title">Indexing Errors</h3></div>
            <div class="panel-body">
              <ul>
                {% for e in page.repo.errors %}
                  <li><em>{{e}}</em></li>
                {% endfor %}
              </ul>
            </div>
          </div>
        {% endif %}
      {% else %}
        <div class="alert alert-warning" role="alert">No version for distro <strong>{{ distro }}</strong>. Known supported distros are highlighted in the buttons above.</div>
      {% endif %}
    </div>
  </div>
{% endfor %}

<script src={{ "/js/contribution_suggestions.js" | prepend: site.baseurl }}></script>
<script type="text/javascript">
  $(function() {
    setupContributeListTabLinks();
  });
  $(document).ready(function() {
    setupDistroSwitch("{{ page.default_distro }}");
    setupContributeLists("{{ page.repo.uri }}");
  });
</script>
